<template>
  <div class="app-container">
    <el-table :data="tableData" class="tableData" style="width: 100%">
      <!-- <el-table-column
        type="index"
        label="序号"
        fixed="left"
        align="center"
        :index="table_index"
        width="50"
      ></el-table-column> -->
    </el-table>
    <div class="pagesCon">
      <div>
        <el-pagination
          :current-page="params.page"
          :page-sizes="[10, 20, 50, 100]"
          :page-size="params.pagesize"
          layout="total, sizes, prev, pager, next, jumper"
          :total="total"
          @size-change="handleSizeChange"
          @current-change="handleCurrentChange"
        />
      </div>
    </div>
  </div>
</template>

<script>
import { exportfun } from "@/api/commJs/index";
export default {
  props: ["url"],
  name: "",
  data() {
    return {
      total: 0,
      tableData: [],
      params: {
        page: 1,
        pagesize: 10
      }
    };
  },
  methods: {
    async list() {
      //exportfun  request1 1:get  0:post
    //   let res = await exportfun(
    //     "com.mmk.report.api.AdminReportProvider/1.0.0/exportAllowance.html",
    //     dates,
    //     1
    //   );
    },
    handleSizeChange(val) {
      this.params.page = 1;
      this.params.pagesize = val;
      this.list();
    },
    handleCurrentChange(val) {
      this.params.page = val;
      this.list();
    }
  }
};
</script>
